let metaEl;
metaEl = document.createElement('meta');
metaEl.setAttribute('name', 'viewport');
if (/Android (\d+\.\d+)/.test(navigator.userAgent)) {
  let version = parseFloat(RegExp.$1);
  if (version > 2.3) {
    let phoneScale = parseInt(window.screen.width) / 750;
    metaEl.setAttribute('content', 'width=750,minimum-scale=' + phoneScale + ',maximum-scale=' + phoneScale + ',target-densitydpi=device-dpi')
  } else {
    metaEl.setAttribute('content', 'width=750,target-densitydpi=device-dpi')
  }
} else {
  metaEl.setAttribute('content', 'width=750,user-scalable=no,target-densitydpi=device-dpi,minimal-ui')
}
document.documentElement.firstElementChild.appendChild(metaEl);

